<?php
defined('IN_ADMIN') or exit('No permission resources.');
$show_dialog = 1;
include $this->admin_tpl('header', 'admin');
?>
<script language="javascript" type="text/javascript" src="<?php echo JS_PATH;?>formvalidator.js" charset="UTF-8"></script>
<script language="javascript" type="text/javascript" src="<?php echo JS_PATH;?>formvalidatorregex.js" charset="UTF-8"></script>
<script type="text/javascript">

</script>
  <style>
/**��� ��**/
.tableK { font-size: 14px; border-spacing: 0px; border-bottom: 1px solid #999; width: 100%; }
.tableK tr th{ background-color: #CFDBEC; font-weight: bold; width: 160px; text-align: right; border-right: none; }
.tableK tr { }
.tableK td { border: 1px solid #999; border-bottom: none; padding: 4px 6px; }
.tableK td input[type='text'] { padding: 2px 4px; width: 300px; border: 1px solid #999; }
.tableK td textarea { border: 1px solid #999; }
.buttonpanle { width: 70%; text-align: center; margin-top: 4px; }
.mf-body-title { height: 40px; line-height: 40px; font-weight: bold; padding-left: 20px; }
</style>
  <div>
	<form action="/index.php?m=hchassorttype&c=crud&a=mylist"  method="post">
		<table class="tableK" border="0">
			<tr>
	            <th>序号</th>
				<td>
					<input type="text" name="id" id="id" value="<?php echo $item['id'] ?>" readonly="readonly"/>
				</td>				
			</tr>
            <tr>
                <th>类型名</th>
                <td>
                    <input type="text" name="item[name]" id="name" value="<?php echo $item['name']?>" />
                </td>
            </tr>
            <tr>
                <th>备注</th>
                <td>
                    <textarea rows="10" cols="50" name="item[remark]" id="remark"><?php echo $item['remark']?></textarea>
                </td>
            </tr>
			<tr>
	            <th>上一级</th>
	            <td>
	            	<select name="item[parent]" id="parent">
	            		<option>请选择</option>
	            		<?php 
	            			foreach ($lists as $li){
								$select = "";
								if($item['parent'] == $li['id']){
									$select = " selected='selected'";
								} 
								echo "<option value='" . $li['id'] . "' " . $select  . " >".$li["name"]."</option>";
							}
	            		?>
	            	</select>
	            	<input type="hidden" name="action" value="edit" />
	            </td>
	          </tr>
	          <tr>
	          	<td colspan="4">
	          		<input type="submit" name="submit" id="submit" value="提交" />
	          	</td>
	          </tr>
	          </tbody>
	      </table>
      </form>
</div>
</body>
</html>